package o;

import android.content.Context;
import android.os.Bundle;
import com.huawei.appgallery.foundation.ui.framework.widget.PullUpListView;
import com.huawei.appgallery.serverreqkit.api.bean.ResponseBean;
import com.huawei.appgallery.serverreqkit.api.bean.ResponseBean.a;
import com.huawei.gamebox.framework.cardkit.bean.WiseJointDetailResponse;
import com.huawei.gamebox.plugin.gameservice.bean.GameInfo;
import java.util.List;

import o.eyi.b;

public class Type1ListSegment extends BaseListSegment {
    private String ʼॱ;
    private String ʽॱ;
    private String ʾ;
    private String ʿ;
    private boolean ˈ = false;
    protected int ॱˋ;
    protected String ॱˎ;
    private String ᐝॱ;

    public static Type1ListSegment ˏ(Context context, Bundle bundle) {
        Type1ListSegment o_bgv = new Type1ListSegment();
        o_bgv.ˊ(bundle);
        o_bgv.ˊ(context);
        return o_bgv;
    }

    protected void ͺ() {
        Bundle ˊˊ = ˊˊ();
        if (ˊˊ != null) {
            this.ˈ = ˊˊ.getBoolean("SUPPORT_NETWROK_CACHE");
            this.ˊ = ˊˊ.getString("SEGMENT_URI");
            this.ॱˋ = ˊˊ.getInt("SEGMENT_INDEX");
            this.ʾ = ˊˊ.getString("SEGMENT_STATKEY");
            this.ᐝॱ = ˊˊ.getString("EVENT_KEY");
            this.ʿ = ˊˊ.getString("EVENT_VALUE");
            this.ͺ = ˊˊ.getString("APPID");
            this.ॱˎ = ˊˊ.getString("PACKAGENAME");
            this.ʽॱ = ˊˊ.getString("GSOURCE");
            this.ʼॱ = ˊˊ.getString("DIRECTORY");
            this.ʽ = ˊˊ.getBoolean("NEED_OBSERVE_ACC", false);
            this.ॱ = ˊˊ.getBoolean("IS_DATA_READY", false);
        } else {
            Logger.e("CardListSegment", "parserArguments, arguments is null");
        }
        ˏॱ();
    }

    public void ॱ(bgq o_bgq, List<cvs> list) {
        eyi ͺ = new b(this.ˊ, this.ʼ).ˊ(25).ˋ(this.ͺ).ˊ(this.ॱˎ).ˏ(this.ʽॱ).ͺ();
        ͺ.ˎ(this.ʼॱ);
        if (this.ˈ && this.ʼ == -1) {
            ͺ.setRequestType(c.ˎ);
        }
        list.add(ͺ);
        Logger.ˎ("CardListSegment", "onPrepareRequestParams, " + ", method: " + ͺ.getMethod_() + ", supportCache: " + this.ˈ + ", requestType: " + ͺ.getRequestType() + ", maxId: " + ͺ.ॱ() + ", detailUri: " + ͺ.ˎ());
    }

    protected void ˊ(BaseRequest o_cvu, ResponseBean responseBean) {
        bet.ˏ(this.ᐝ, o_cvu, responseBean);
        if (responseBean instanceof WiseJointDetailResponse) {
            this.ʼ = ((WiseJointDetailResponse) responseBean).ˏ();
        }
    }

    protected void ˏ(BaseRequest o_cvu, ResponseBean responseBean) {
        if (!(ʼ() || this.mLoadCtrl == null)) {
            this.mLoadCtrl.ॱ(0, 0);
            ˊ(true);
            this.mLoadCtrl = null;
        }
        ˎ(true);
        ˋ(responseBean.getResponseType() == a.ˏ);
        if (responseBean instanceof WiseJointDetailResponse) {
            refreshTitle(((WiseJointDetailResponse) responseBean).ˋ());
            ezs.ˏ().ॱ(ˊᐝ(), o_cvu, responseBean);
        }
        if (this.mListView != null) {
            boolean z;
            PullUpListView pullUpListView = this.mListView;
            if (responseBean.getResponseType() != a.ˋ) {
                z = true;
            } else {
                z = false;
            }
            pullUpListView.setEnableChangeLoadingView(z);
        }
        ˊ(o_cvu, responseBean);
        if (this.ᐝ == null || this.ᐝ.ˊॱ() <= 0) {
            ˊ(false);
            ˏ(true);
        } else {
            ˊ(true);
            ˏ(false);
        }
        ॱ(0);
    }

    public String toString() {
        return "detailUri:" + this.ˊ + ";eventKey:" + this.ᐝॱ + ";eventValue:" + this.ʿ + ";stateKey:" + this.ʾ;
    }

    private GameInfo ˊᐝ() {
        fae ˏ = fam.ॱ().ˏ();
        if (ˏ != null) {
            return ˏ.getGameInfo();
        }
        return null;
    }
}
